import junit.framework.*;

public class TestHuffman extends TestCase {

	String[] cadena = new String[7];
	Huffman vector = new Huffman(cadena);
	
	public TestHuffman(){
	cadena[0] = "a";
	cadena[1] = "b";
	cadena[2] = "a";
	cadena[3] = "c";
	cadena[4] = "c";
	cadena[5] = "d";
	cadena[6] = "a";
	}
	
	public void test() {
		
	
		int[] frec = vector.frecuencia();
			
		assertEquals(3, frec[0]);
		assertEquals(1, frec[1]);
		assertEquals(2, frec[2]);
		assertEquals(1, frec[3]);
		assertEquals(0, frec[4]);
		assertEquals(0, frec[5]);
		
		
	}
}